/*
 * controller.h
 */

#ifndef CONTROLLER_H_
#define CONTROLLER_H_

#include "action.h"

/*
 * Creates a new controller object.
 */
int controller_init();

/*
 * Adds the given function pointer to the controller's action queue.
 */
void controller_add(action *a);

/*
 * Pops the next event off the queue and executes it.
 * If the queue is empty, controller_next() does nothing.
 */
int controller_next();

/*
 * Pops every event off the queue and executes it until the queue is empty.
 */
void controller_empty();

#endif
